Statistical modelling / Fitting Wood's curve

The PRINT statement at the end of the series of statements shows that the average values for the estimates are:


    MeanEst
     2.2427
     0.1562
    -0.0045

We can now calculate average fitted values by preparing the statements below. We define a variable nday to have values between 5 and 270 at 5 day intervals and calculate the predicted value for average milk yield (avemilk) for each value of nday.

 

    VARIATE [NVALUES=54; VALUES=(1...54)] nday,avemilk
    CALCULATE nday = nday*5
    CALCULATE avemilk = MeanEst$[1] + MeanEst$[2]*LOG(nday)+MeanEst$[3]*nday
    CALCULATE avemilk = EXP(avemilk)

Note the facility in GenStat for using the $ syntax for identifying individual levels of a vector.